<?php
/**
 * P�gina respons�vel por agrupar todos os passos da avalia��o da compra, que s�o: 
 * 1 - Inicio ( ExibirInformacoesProcesso.php )
 * 2 - Fundamento Legal ( AvaliarEstrategiaContratacao.php )
 * 3 - Revisar Objetos ( RevisarObjetosProcesso.php )
 * 4 - Mapa de Apura��o ( abrirMapaApuracao.php )
 * 5 - Despacho ( DespacharProcessoCompra.php )
 * 
 * Todas as p�ginas acimas s�o inseridas via AJAX ( compra.js ) no div desta p�gina 
 * cujo id � "tdInclude".
 */
if(!isset($_SESSION))
{
    session_start();
}

if( !function_exists('__autoload') )
{
    function __autoload($class_name) {
    require_once $class_name . '.php';
    }
}

SAEO::ValidarAcesso( array( 0, 2, 3, 4 ) );

?>
<html>
<head id='head'>
      <title>SAEO - Avaliar Compra</title>
      <script type='text/javascript' src='templates/hintbox.js'></script>
      <script type='text/javascript' src='templates/compra.js'></script>
      <script type='text/javascript' src='templates/ajax-dynamic-content.js'></script>
      <script type='text/javascript' src='templates/ajax.js'></script>
      <script type='text/javascript' src='templates/geral.js'></script>
      <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
      <script>
      
      </script>
      <link rel='stylesheet' type='text/css' href='templates/estilos.css'>
</head>	
<body class='body'>
      <table width='779' border='0' cellspacing='0' cellpadding='0' align='center' bgcolor='#FFFFFF'>
             <tr>
                 <td><?php include 'Topo.php'; ?></td>
             </tr>
             <tr>
                 <td><div class='titulosTabelas' style='width:779; height:20; background:url(templates/tabela.jpg)'>Avaliar compra</div></td>
             </tr>
             <tr>
                 <td>&nbsp;</td>
             </tr>
             <tr>
                 <td><table class='tabela' width='650' border='0' cellspacing='5' cellpadding='0' align='center' bgcolor='#FFFFFF'>
                 		<?php 
                 		if ($_SESSION['servidorPerfil'] == 4)
                 		{
                 		?>
                     	<tr>
                        	<td class='avaliarCompraSelecionada' id='inicio' width='20%' onClick='inicio(<?php echo $_GET['processoId'].", ".$_GET['juncao'] ?>);'>INICIO</td>
                            <td class='avaliarCompra' id='revisarObjetos' width='20%' onClick='revisarObjetos(<?php echo $_GET['processoId'].", ".$_GET['juncao'] ?>);'>REVISAR OBJETOS</td>
                            <td class='avaliarCompra' id='fundamentoLegal' width='20%' onClick='fundamentoLegal(<?php echo $_GET['processoId'].", ".$_GET['juncao'] ?>);'>FUNDAMENTO LEGAL</td>
                            <td class='avaliarCompra' id='mapaApuracao' width='20%' onClick='mapaApuracao(<?php echo $_GET['processoId'].", ".$_GET['juncao'] ?>);'>MAPA DE APURA��O</td>
                            <td class='avaliarCompra' id='despachar' width='20%' onClick='despachar(<?php echo $_GET['processoId'].", ".$_GET['juncao'] ?>);'>DESPACHAR</td>
                        </tr>
                        <?php 
                 		}else{
                 		?>
                 		<tr>
                        	<td class='avaliarCompraSelecionada' id='inicio' width='50%' height='50px' onClick='inicio(<?php echo $_GET['processoId'].", ".$_GET['juncao'] ?>);'>INICIO</td>
                            <td class='avaliarCompra' id='despachar' width='50px' onClick='despachar(<?php echo $_GET['processoId'].", ".$_GET['juncao'] ?>);'>DESPACHAR</td>
                        </tr>
                        <?php 
                 		}
                 		?>
                        <tr>
                        	<td colspan='5'>
                            	<div id='tdInclude' style='display:block;'>
									<?php include 'ExibirInformacoesProcesso.php'; ?>
						        </div>
                           </td>
                        </tr>
        			</table>
        		  </td>
        	</tr>
        	<tfoot>
        		<tr>
        			<td>&nbsp</td>
        		</tr>
				<tr>
					<?php include 'rodapeCreditos.php'; ?>
				</tr>
            </tfoot>
      </table>
</body>
</html>